home *** CD-ROM | disk | FTP | other *** search
/ ADA Programming Guide / ADA Programming Guide.iso / ada_gnu / include / sys / wait.h < prev   
C/C++ Source or Header  |  1996-01-30  |  712b  |  23 lines

  1. /*
  2.   (c) Copyright 1992 Eric Backus
  3.  
  4.   This software may be used freely so long as this copyright notice is
  5.   left intact.  There is no warrantee on this software.
  6. */
  7.  
  8. /* Needed only for waitpid() and wait3() */
  9. /* #define    WNOHANG        1 */
  10. /* #define    WUNTRACED    2 */
  11. /* #define    _WAITMASK    (WNOHANG | WUNTRACED) */
  12.  
  13. /* Needed for wait() */
  14. #define    WIFEXITED(_x)    (((int) (_x) & 0xff) == 0)
  15. #define    WIFSTOPPED(_x)    (((int) (_x) & 0xff) == 0x7f)
  16. #define    WIFSIGNALED(_x)    ((((int) (_x) & 0xff) != 0) &&\
  17.              (((int) (_x) & 0xff) != 0x7f))
  18. #define    WEXITSTATUS(_x)    (((int) (_x) >> 8) & 0xff)
  19. #define    WTERMSIG(_x)    ((int) (_x) & 0x7f)
  20. #define    WSTOPSIG(_x)    (((int) (_x) >> 8) & 0xff)
  21.  
  22. #include <djgppstd.h>
  23.